home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Technotools
/
Technotools (Chestnut CD-ROM)(1993).ISO
/
lang_c
/
cgraphix
/
cstxt.c
< prev
next >
Wrap
Text File
|
1986-05-28
|
814b
|
38 lines
/* «RM120»«PL99999»«TS4,8,12,16,20,24,28,32,36,40,44,48,52,56,60,64,68,72,76» */
#include <stdio.h>
#define MaxWorldX 1000.0
#define MaxWorldY 1000.0
main()
{
int i;
double CharHeight, CharWidth;
InitGraphic();
DefineWorld(1, 0., 0., MaxWorldX, MaxWorldY);
SelectWorld(1);
SelectWindow(1);
DrawBorder();
GotoXY(39,12);
DisplayString("* <- This should be at the center \r\n");
DisplayString("This should be on the next line");
GotoXY(39,13);
DisplayString("This should be on the next line");
CharWidth = MaxWorldX / 80.;
CharHeight = MaxWorldY / 25.;
DrawSquare((double)(9*CharWidth), (double)(7*CharHeight),
(double)((22*CharWidth)+2), (double)((8*CharHeight)+2), FALSE);
GotoXY(9,7);
DisplayString("Text in a box");
inkey();
LeaveGraphic();
}